#ifndef ACCESSORY_LIB_H
#define ACCESSORY_LIB_H
#include<iostream>
#include<string>
#include <libusb.h>

typedef signed char             int8;
typedef signed short            int16;
typedef signed long             int32;
typedef signed long long        int64;
typedef unsigned char           uint8;
typedef unsigned short          uint16;
typedef unsigned long           uint32;
typedef unsigned long long      uint64;
typedef int            ipod_t;

struct accessory_bulk_handle{
	uint8 addr;
};

class AccessoryLib {

public:
	~AccessoryLib();

	static AccessoryLib* getInstance();
	int  accessoryLibCreate(void (*pFunc)( ));
	int  accessoryLibInit();
	int  accessoryLibUninit();
	void accessoryLibDestory();
	int accessoryWrite(uint8 *data, uint16 len,int * length);
	int accessoryRead(uint8 *data, uint16 len,int * length);
	int accessoryUsbVidPid(uint16 *vid, uint16 *pid,int * length);

private:
	AccessoryLib();
	static AccessoryLib* pInstance;
};

#endif
